|
|
|
|
|
|
|
Perspective projection onto the X-Y plane with center of projection at (0, 0, d): |
|
|
|
|
|
|
|
|
Reflection across an arbitrary plane: |
|
|
|
|
|
|
|
|
1. Translate the plane so that it intersects the origin. |
|
|
|
|
|
|
|
|
2. Rotate around the Z axis until the normal vector lies in the Y-Z plane. |
|
|
|
|
|
|
|
|
3. Rotate around the X axis to make the normal vector lie along the Y axis. |
|
|
|
|
|
|
|
|
4. Reflect across the X-Z plane. |
|
|
|
|
|
|
|
|
5. Reverse the second rotation. |
|
|
|
|
|
|
|
|
6. Reverse the first rotation. |
|
|
|
|
|
|
|
|
7. Reverse the translation. |
|
|
|
|
|
|
|
|
Rotation around an arbitrary line: |
|
|
|
|
|
|
|
|
1. Translate the line to the origin. |
|
|
|
|
|
|
|
|
2. Rotate around the Z axis until the line lies in the Y-Z plane. |
|
|
|
|
|
|
|
|
3. Rotate around the X axis until the line lies along the Y axis. |
|
|
|
|
|
|
|
|
4. Rotate around the Y axis. |
|
|
|
|
|
|
|
|
5. Reverse the second rotation. |
|
|
|
|
|
|
|
|
6. Reverse the first rotation. |
|
|
|
|
|
|
|
|
7. Reverse the translation. |
|
|
|
|
|
|
|
|
Projection onto an arbitrary plane: |
|
|
|
|
|
|
|
|
1. Translate the focus to the origin. |
|
|
|
|
|
|
|
|
2. Rotate around the Y axis to place the center of projection in the Y-Z plane. |
|
|
|
|
|
|
|
|
3. Rotate around the X axis until the center of projection lies on the Z axis. |
|
|
|
|
|
|
|
|
4. Project (parallel or perspective) along the Z axis onto the X-Y plane. |
|
|
|
|
|
|
|
|
Projection onto an arbitrary plane with an UP vector: |
|
|
|
|
|
|
|
|
1. Translate the focus to the origin. |
|
|
|
|
|
|
|
|
2. Rotate around the Y axis to place the center of projection in the Y-Z plane. |
|
|
|
|
|
|
|
|
3. Rotate around the X axis until the center of projection lies on the Z axis. |
|
|
|
|
|
|
|
|
4. Rotate around the Z axis until the UP vector lies in the Y-Z plane. |
|
|
|
|
|
|
|
|
5. Project (parallel or perspective) along the Z axis onto the X-Y plane. |
|
|
|
|
|